<div class="container">
  <form *ngIf="!taskInfoAdded" class="ui form" (ngSubmit)="onSubmit()" #addPhotoForm = "ngForm">
    <h2 class="ui dividing header">Add Your Task</h2>
    <div class="field">
      <div class = "two fields">
        <div class="field">
          <label>* Task Name</label>
          <input type="text" name="TaskName" placeholder="Task Name" [(ngModel)]="newTaskInfo.TaskName" required />
        </div>
        <div class="field">
          <label>* Task Describle</label>
          <input type="text" name="TaskDescrible" placeholder="Description" [(ngModel)]="newTaskInfo.TaskDescrible" />
        </div>
      </div>
    </div>
    <div class="field">
      <div class = "two fields">
        <div class="field">
          <label>* Task StartTime</label>
          <input type="date" name="StartTime" placeholder="Task StartTime" [(ngModel)]="newTaskInfo.StartTime" required />
        </div>
        <div class="field">
          <label>* Task EndTime</label>
          <input type="date" name="EndTime" placeholder="Task EndTime" [(ngModel)]="newTaskInfo.EndTime" required />
        </div>
      </div>
    </div>
    
    <hr />
    <br />
    <button type="submit" class="ui button">Submit</button>
  </form>


<div *ngIf = "taskInfoAdded">
  <h1>Add Task Success!</h1>
</div>

</div>
